Building a System Info Viewer in Batch: A Beginner's Guide
A batch program that displays various system information, such as CPU and memory usage, disk space, network status, and more. This can be done using various built-in commands and utilities, such as systeminfo, tasklist, netstat, and wmic.
A System Info Viewer batch program that displays various system information:
|
@echo off echo *** System Information Viewer *** echo. echo === Operating System === systeminfo | findstr /B /C:"OS Name" /C:"OS Version" /C:"System Type" echo. echo === Processor === wmic cpu get name, caption, architecture, maxclockspeed, currentclockspeed, numberofcores, numberoflogicalprocessors echo. echo === Memory === wmic MEMORYCHIP get BankLabel, Capacity, Speed echo. echo === Storage === wmic diskdrive get caption, size, interfacetype echo. echo === Network === ipconfig |
steps to save and run a batch file:
- Open a text editor like Notepad.
- Copy a above batch code.
- Save the file with spec.bat extension.
- Choose a location to save the file. You can save it anywhere on your computer, but it's a good idea to save it in a location that's easy to remember and access.
- Double-click on the spec .bat file to run it. Alternatively, you can open a Command Prompt window, navigate to the directory where the .bat file is saved, and type the name of the file followed by Enter to run it.

Comments
Post a Comment